﻿using SMARTMobile.WinPhone.Models;

namespace SMARTMobile.Models.UI
{
    public class ARSaleSPModel : BaseModel<ARSaleSPModel>
    {
        private string _key;
        private string _name;
        private string _phone1;
        private string _phone2;
        private string _sscode;
        private string _ssname;
        private string _image;
        private string _siteCode;
        private string _logo;
        private string _address;
        private string _curLat;
        private int _curLong;

        public ARSaleSPModel()
        {
            this.Key = string.Empty;
            this.Name = Localization.AppResources.ROUTECHECK_LABEL_ARSALESP;
        }

        public string Key
        {
            get { return this._key; }
            set
            {
                this._key = value;
                base.RaisePropertyChanged("Key");
            }
        }

        public string Name
        {
            get { return this._name; }
            set
            {
                this._name = value;
                base.RaisePropertyChanged("Name");
            }
        }

        public string Phone1
        {
            get { return this._phone1; }
            set
            {
                this._phone1 = value;
                base.RaisePropertyChanged("Phone1");
            }
        }

        public string Phone2
        {
            get { return this._phone2; }
            set
            {
                this._phone2 = value;
                base.RaisePropertyChanged("Phone2");
            }
        }

        public string SSCode
        {
            get { return this._sscode; }
            set
            {
                this._sscode = value;
                base.RaisePropertyChanged("SSCode");
            }
        }

        public string SSName
        {
            get { return this._ssname; }
            set
            {
                this._ssname = value;
                base.RaisePropertyChanged("SSName");
            }
        }

        public string Image
        {
            get { return this._image; }
            set
            {
                this._image = value;
                base.RaisePropertyChanged("Image");
            }
        }

        public string SiteCode
        {
            get { return this._siteCode; }
            set
            {
                this._siteCode = value;
                base.RaisePropertyChanged("SiteCode");
            }
        }

        public string Logo
        {
            get { return this._logo; }
            set
            {
                this._logo = value;
                base.RaisePropertyChanged("Logo");
            }
        }

        public string Address
        {
            get { return this._address; }
            set
            {
                this._address = value;
                base.RaisePropertyChanged("Address");
            }
        }

        public string CurLat
        {
            get { return this._curLat; }
            set
            {
                this._curLat = value;
                base.RaisePropertyChanged("CurLat");
            }
        }

        public int CurLong
        {
            get { return this._curLong; }
            set
            {
                this._curLong = value;
                base.RaisePropertyChanged("CurLong");
            }
        }

        public override string ToString()
        {
            if (string.IsNullOrEmpty(this.Key))
                return string.Format("{0} - {1}", this.Key, this.Name);
            else
                return this.Name;
        }
    }
}
